<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <title>Login</title>
    <link rel="stylesheet" th:href="@{/css/style.css}" />
</head>
<body>
<div class="login-container">
    <h2>登录</h2>
    <form th:action="@{/login}" method="post">
        <div>
            <label for="username">用户名:</label>
            <input type="text" id="username" name="username" required />
        </div>
        <div>
            <label for="password">密码:</label>
            <input type="password" id="password" name="password" required />
        </div>
        <button type="submit">Login</button>
    </form>
    <p th:if="${param.error}" class="error">Invalid username or password.</p>
    <p th:if="${param.logout}" class="logout">You have been logged out.</p>
</div>
</body>
</html>
